package com.travel.server.manager.dao;

import com.travel.server.manager.model.ProjectInfo;
import com.travel.server.manager.model.ProjectInfoExample;

import java.util.Date;
import java.util.List;

import com.travel.server.manager.model.dto.ProjectEnumDto;
import com.travel.server.manager.model.dto.data.ProjectOrderDto;
import com.travel.server.manager.model.dto.data.ProjectTrendDto;
import org.apache.ibatis.annotations.Param;

public interface ProjectInfoDao {
    int countByExample(ProjectInfoExample example);

    int deleteByExample(ProjectInfoExample example);

    int deleteByPrimaryKey(Integer id);

    int insert(ProjectInfo record);

    int insertSelective(ProjectInfo record);

    List<ProjectInfo> selectByExample(ProjectInfoExample example);

    ProjectInfo selectByPrimaryKey(Integer id);

    int updateByExampleSelective(@Param("record") ProjectInfo record, @Param("example") ProjectInfoExample example);

    int updateByExample(@Param("record") ProjectInfo record, @Param("example") ProjectInfoExample example);

    int updateByPrimaryKeySelective(ProjectInfo record);

    int updateByPrimaryKey(ProjectInfo record);

    List<String> selectEnum(ProjectEnumDto projectEnumDto);

    int updateProjectType(@Param("oldProjectType") String oldProjectType, @Param("newProjectType") String newProjectType);

    int updateProject(@Param("oldProject") String oldProject, @Param("newProject") String newProject);

    int selectShelf();

    List<ProjectOrderDto> selectProjectOrder(@Param("startTime") Date startTime, @Param("endTime") Date endTime, @Param("country") Integer country,
                                             @Param("projectName") String projectName, @Param("state") Integer state, @Param("offset") Integer offset, @Param("limit") Integer limit);

    List<ProjectTrendDto> selectProjectTrend(@Param("startTime") Date startTime, @Param("endTime") Date endTime, @Param("specialIdList") List<Integer> specialIdList,
                                             @Param("orderStepList") List<String> orderStepList, @Param("state") Integer state);

    int selectOrderChargeCount();
}